﻿<style type="text/css">
    .auto-style1 {
        width: 400px;
    }

    .easyui-textbox {
        width: 430px;
    }

    .auto-style2 {
        width: 150px;
    }

    .easyui-combobox {
        width: 430px;
    }
</style>
@{
    Layout = null;
}

<!DOCTYPE html>

<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
    <title>勘察管理</title>
    <link href="~/css/css_1.css" rel="stylesheet" />
    <link rel="stylesheet" type="text/css" href="../../easyUI/themes/default/easyui.css">
    <link rel="stylesheet" type="text/css" href="../../easyUI/themes/icon.css">
    <script type="text/javascript" src="../../easyUI/jquery.min.js"></script>
    <script type="text/javascript" src="../../easyUI/jquery.easyui.min.js"></script>

    <script>
        $(function () {
            jiazai();

            sel("位置环绕", "location_Position");
            sel("交通便捷度", "location_Convenient");
            sel("自然人文环境质量", "location_Quality");
            sel("居住社区成熟度", "location_Mature");
            sel("基础设施配套度", "ocation_Degree");
            sel("配套设施", "location_Supporting");
            sel("来源", "village_Cause");
            sel("小区封闭性", "village_Close");
            sel("居住小区楼宇构成", "village_Structure");
            sel("交通组织方式", "village_Traffic");
            sel("景观及绿化", "village_Green");
            sel("容积率", "village_Volume");
            sel("车位状况", "village_Parking");
            sel("物业公司", "village_Property");
            sel("房屋实际用途", "indoor_Purpose");
            sel("朝向", "indoor_Orientation");
            sel("建筑类型", "floor_BuildType");
            sel("住宅类型", "indoor_Residence");
            sel("外立面装饰", "floor_Facade");
            sel("公共部位装修", "floor_Public");
            sel("电梯", "floor_Lift");
            sel("供气", "floor_Gas");
            sel("供水", "floor_Water");
            sel("供暖", "floor_Warm");
            sel("门禁系统", "floor_Door");
            sel("客厅装修程度", "s1");
            sel("房屋结构", "floor_HouseStructure");
            sel("客厅装修程度2", "indoor_HallDegree");
            sel("客厅装修程度2", "indoor_RoomDegree");
            sel("客厅装修程度2", "indoor_ToiletDegree");
            sel("客厅装修程度2", "indoor_KitchenDegree");
        })

        //下拉方法
        function sel(name, id) {
            $.ajax({
                url: "http://localhost:25744/api/Dictionary?Dictionary_Type=" + name,
                dataType: "json",
                type: "get",
                success: function (obj) {
                    var data = eval(obj);
                    $("#" + id + "").combobox({
                        data: data,
                        valueField: 'dictionary_Id',
                        textField: 'dictionary_Name'
                    })
                }
            })
        }

        //首次加载勘察信息
        function jiazai() {
            $.ajax({
                url: "http://localhost:25744/api/Project",
                type: "get",
                data:{survey:3,basic_State:90},
                dataType: "json",
                success: function (data1) {
                    var msg = eval(data1);
                    $('#kancha').datagrid( {
                        data: msg,
                        onClickRow:function(index,row)
                        {
                            $("#projectNumber").textbox("setValue", row.projectNumber);
                        }
                    });
                }
            })
        }

        //首次加载询价
        function xunjia() {
            var projectNumber = $("#projectNumber").val();
            $.ajax({
                url: "http://localhost:25744/api/Inquiry",
                type: "get",
                data:{projectNumber:projectNumber},
                dataType: "json",
                success: function (data1) {
                    var msg = eval(data1);
                    $('#xunjia').datagrid('loadData', msg);
                }
            })
        }

        //打开区位状况
        function tianqu() {
            var row = $('#kancha').datagrid('getSelected');
            if (row) {
                $('#qu').window('open');
            }
        }

        //打开小区状况
        function tianxiao() {
            var row = $('#kancha').datagrid('getSelected');
            if (row) {
                $('#xiao').window('open');
            }
        }
        //打开建筑公共安全状况
        function tianjian() {
            var row = $('#kancha').datagrid('getSelected');
            if (row) {
                $('#jian').window('open');
            }
        }
        //打开室内状况
        function tianshi() {
            var row = $('#kancha').datagrid('getSelected');
            if (row) {
                $('#shi').window('open');
            }
        }
        //打开现场照片
        function tianxian() {
            var row = $('#kancha').datagrid('getSelected');
            if (row) {
                $('#xian').window('open');
            }
        }
        //打开状询价记录
        function tianxun() {
            var row = $('#kancha').datagrid('getSelected');
            if (row) {
                $('#xun').window('open');
                xunjia();
            }
        }
        //打开勘察详情
        function tianshen() {
            var row = $('#kancha').datagrid('getSelected');
            if (row) {
               // $('#qu').window('open');
            }

        }
        //打开添加询价
        function tianaxun() {
            $('#axun').window('open');
        }

        //添加区位状况
        function addqu() {
            var projectNumber = $("#projectNumber").val();
            $.ajax({
                url: "http://localhost:25744/api/Location",
                type: "post",
                data: {
                    projectNumber:$("#projectNumber").val(),
                    location_East: $("#location_East").val(),
                    location_South: $("#location_South").val(),
                    location_West: $("#location_West").val(),
                    location_North: $("#location_North").val(),
                    location_Position: $("#location_Position").combobox('getValue'),
                    location_Traffic: $("#location_Traffic").val(),
                    location_Convenient: $("#location_Convenient").combobox('getValue'),
                    location_Humanity: $("#location_Humanity").val(),
                    location_Quality: $("#location_Quality").combobox('getValue'),
                    location_Community: $("#location_Community").val(),
                    location_Mature: $("#location_Mature").combobox('getValue'),
                    location_Facilities: $("#location_Facilities").val(),
                    ocation_Degree: $("#ocation_Degree").combobox('getValue'),
                    location_Supporting: $("#location_Supporting").combobox('getValue'),
                    location_Explain: $("#location_Explain").val()
                },
                success: function (sql) {
                    if (sql > 0) {
                        alert('保存成功')
                    }
                    else {
                        alert('保存失败')
                    }
                }
            })
        }
        //添加小区状况
        function addxiao() {
            $.ajax({
                url: "http://localhost:25744/api/Village",
                type: "post",
                data: {
                    projectNumber: $("#projectNumber").val(),
                    village_CaseName: $("#village_CaseName").val(),
                    village_Cause: $("#village_Cause").combobox('getValue'),
                    village_Close: $("#village_Close").combobox('getValue'),
                    village_Structure: $("#village_Structure").combobox('getValue'),
                    village_Traffic: $("#village_Traffic").combobox('getValue'),
                    village_Green: $("#village_Green").combobox('getValue'),
                    village_Volume: $("#village_Volume").combobox('getValue'),
                    village_Parking: $("#village_Parking").combobox('getValue'),
                    village_Property: $("#village_Property").combobox('getValue'),
                    village_Explain: $("#village_Explain").val()
                },
                success: function (sql) {
                    if (sql > 0) {
                        alert('保存成功')
                    }
                    else {
                        alert('保存失败')
                    }
                },
            })
        }
        //添加室内状况
        function addshi() {
            var living_Wall = "";
            $(".living_Wall:checked").each(function () {
                living_Wall += $(this).val() + ",";
            })
            var living_Ceiling = "";
            $(".living_Ceiling:checked").each(function () {
                living_Ceiling += $(this).val() + ",";
            })
            var living_Ground = "";
            $(".living_Ground:checked").each(function () {
                living_Ground += $(this).val() + ",";
            })
            var room_Wall = "";
            $(".room_Wall:checked").each(function () {
                room_Wall += $(this).val() + ",";
            })
            var room_Ceiling = "";
            $(".room_Ceiling:checked").each(function () {
                room_Ceiling += $(this).val() + ",";
            })
            var room_Ground = "";
            $(".room_Ground:checked").each(function () {
                room_Ground += $(this).val() + ",";
            })
            var toilet_Wall = "";
            $(".toilet_Wall:checked").each(function () {
                toilet_Wall += $(this).val() + ",";
            })
            var toilet_Ceiling = "";
            $(".toilet_Ceiling:checked").each(function () {
                toilet_Ceiling += $(this).val() + ",";
            })
            var toilet_Ground = "";
            $(".toilet_Ground:checked").each(function () {
                toilet_Ground += $(this).val() + ",";
            })
            var toilet_Sanitary = "";
            $(".toilet_Sanitary:checked").each(function () {
                toilet_Sanitary += $(this).val() + ",";
            })
            var kitchen_Wall = "";
            $(".kitchen_Wall:checked").each(function () {
                kitchen_Wall += $(this).val() + ",";
            })
            var kitchen_Ceiling = "";
            $(".kitchen_Ceiling:checked").each(function () {
                kitchen_Ceiling += $(this).val() + ",";
            })
            var kitchen_Ground = "";
            $(".kitchen_Ground:checked").each(function () {
                kitchen_Ground += $(this).val() + ",";
            })
            var kitchen_Cooking = "";
            $(".kitchen_Cooking:checked").each(function () {
                kitchen_Cooking += $(this).val() + ",";
            })
            $.ajax({
                url: "http://localhost:25744/api/Indoor",
                type: "post",
                data: {
                    projectNumber: $("#projectNumber").val(),
                    indoor_Purpose: $("#indoor_Purpose").combobox('getValue'),
                    indoor_LayerNum: $("#indoor_LayerNum").val(),
                    indoor_Layer: $("#indoor_Layer").val(),
                    indoor_Orientation: $("#indoor_Orientation").combobox('getValue'),
                    indoor_Residence: $("#indoor_Residence").combobox('getValue'),
                    indoor_Bedroom: $("#indoor_Bedroom").val(),
                    indoor_Hall: $("#indoor_Hall").val(),
                    indoor_Toilet: $("#indoor_Toilet").val(),
                    indoor_Balcony: $("#indoor_Balcony").val(),
                    indoor_Terrace: $("#indoor_Terrace").val(),
                    indoor_HallDegree: $("#indoor_HallDegree").combobox('getValue'),
                    indoor_RoomDegree: $("#indoor_RoomDegree").combobox('getValue'),
                    indoor_ToiletDegree: $("#indoor_ToiletDegree").combobox('getValue'),
                    indoor_KitchenDegree: $("#indoor_KitchenDegree").combobox('getValue'),
                    indoor_Explain: $("#indoor_Explain").val(),
                    livingWall_Other: $("#livingWall_Other").val(),
                    livingCeiling_Other: $("#livingCeiling_Other").val(),
                    livingGround_Other: $("#livingGround_Other").val(),
                    roomWall_Other: $("#roomWall_Other").val(),
                    roomCeiling_Other: $("#roomCeiling_Other").val(),
                    roomGround_Other: $("#roomGround_Other").val(),
                    toiletWall_Other: $("#toiletWall_Other").val(),
                    toiletCeiling_Other: $("#toiletCeiling_Other").val(),
                    toiletGround_Other: $("#toiletGround_Other").val(),
                    toiletSanitary_Other: $("#toiletSanitary_Other").val(),
                    kitchenWall_Other: $("#kitchenWall_Other").val(),
                    kitchenCeiling_Other: $("#kitchenCeiling_Other").val(),
                    kitchenGround_Other: $("#kitchenGround_Other").val(),
                    kitchenCookingO_ther: $("#kitchenCookingO_ther").val(),
                    living_Wall: living_Wall.substr(0, living_Wall.length - 1),
                    living_Ceiling: living_Ceiling.substr(0, living_Ceiling.length - 1),
                    living_Ground: living_Ground.substr(0, living_Ground.length - 1),
                    room_Wall: room_Wall.substr(0, room_Wall.length - 1),
                    room_Ceiling: room_Ceiling.substr(0, room_Ceiling.length - 1),
                    room_Ground: room_Ground.substr(0, room_Ground.length - 1),
                    toilet_Wall: toilet_Wall.substr(0, toilet_Wall.length - 1),
                    toilet_Ceiling: toilet_Ceiling.substr(0, toilet_Ceiling.length - 1),
                    toilet_Ground: toilet_Ground.substr(0, toilet_Ground.length - 1),
                    toilet_Sanitary: toilet_Sanitary.substr(0, toilet_Sanitary.length - 1),
                    kitchen_Wall: kitchen_Wall.substr(0, kitchen_Wall.length - 1),
                    kitchen_Ceiling: kitchen_Ceiling.substr(0, kitchen_Ceiling.length - 1),
                    kitchen_Ground: kitchen_Ground.substr(0, kitchen_Ground.length - 1),
                    kitchen_Cooking: kitchen_Cooking.substr(0, kitchen_Cooking.length - 1)
                },
                success: function (sql) {
                    if (sql > 0) {
                        alert('保存成功')
                    }
                    else {
                        alert('保存失败')
                    }
                },
            })
        }
        //添加建筑公共安全状况
        function addjian() {
            $.ajax({
                url: "http://localhost:25744/api/Floors",
                type: "post",
                data: {
                    projectNumber: $("#projectNumber").val(),
                    floor_Number: $("#floor_Number").val(),
                    floor_Landmark: $("#floor_Landmark").val(),
                    floor_Address: $("#floor_Address").val(),
                    floor_HouseStructure: $("#floor_HouseStructure").combobox('getValue'),
                    floor_BuildType: $("#floor_BuildType").combobox('getValue'),
                    floor_Facade: $("#floor_Facade").combobox('getValue'),
                    floor_Public: $("#floor_Public").combobox('getValue'),
                    floor_Lift: $("#floor_Lift").combobox('getValue'),
                    floor_LiftNum: $("#floor_LiftNum").val(),
                    floor_Gas: $("#floor_Gas").combobox('getValue'),
                    floor_Water: $("#floor_Water").combobox('getValue'),
                    floor_Warm: $("#floor_Warm").combobox('getValue'),
                    floor_Door: $("#floor_Door").combobox('getValue'),
                    floor_Explain: $("#floor_Explain").val(),
                },
                success: function (sql) {
                    if (sql > 0) {
                        alert('保存成功')
                    }
                    else {
                        alert('保存失败')
                    }
                }
            })
        }
        //添加询价记录
        function addxun() {
            $.ajax({
                url: "http://localhost:25744/api/Inquiry",
                type: "post",
                data: {
                    projectNumber: $("#projectNumber").val(),
                    floor_Number: $("#projectNumber").val(),
                    floor_Landmark: $("#inquiry_UnitPrice").val(),
                    floor_Address: $("#inquiry_Content").val(),
                    floor_Address: $("#inquiry_Time").val()
                },
                success: function (sql) {
                    if (sql > 0) {
                        alert('保存成功');
                        $('#axun').window('close');
                        xunjia();
                    }
                    else {
                        alert('保存失败')
                    }
                }
            })
        }
        //操作栏
        function formatOper(val, row, index) {
            var s = "<a href='#' onclick='uptstate(" + row.basic_id + ")'>结束勘察</a>";
            return s;
        }

        //结束勘察
        function uptstate(basic_id)
        {
           
            $.ajax({
                url: "http://localhost:25744/api/Survey",
                type: "Put",
                data: { basic_id: basic_id ,basic_State:91},
                success: function (data) {
                    if (data > 0) {
                        alert('已结束勘察');
                        jiazai();
                    }
                    else {
                        alert("结束失败");
                    }
                }
                });
        }



    </script>

    <!--地图密钥-->
    <script type="text/javascript" src="http://api.map.baidu.com/api?v=2.0&ak=BD7KBAtjCu33g3q2RLPcUmDlVwbkjbAw">
        //v2.0版本的引用方式：src="http://api.map.baidu.com/api?v=2.0&ak=您的密钥"
    </script>

</head>
<body class="bb1">
    <input class="easyui-textbox" type="text" name="loan_IdCard" id="loan_IdCard">
    <a href="#" class="easyui-linkbutton" data-options="iconCls:'icon-search'" style="width:80px">查询</a><br />
    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianqu()">区位状况勘察</a>
    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianxiao()">小区状况勘察</a>
    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianjian()">建筑公共部分状况勘察</a>
    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianshi()">室内状况勘察</a>
    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianxian()">现场照片提供</a>
    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianxun()">询价记录</a>
    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianshen()">勘察详情</a>

    <!--我的勘察-->
    <table class="easyui-datagrid" title="我的勘察" data-options="singleSelect:true,collapsible:true" style="width:85%;height:90%" id="kancha">
       
            <thead>
                <tr>
                    <th data-options="field:'basic_id',width:80,align:'center'">项目号</th>
                    <th data-options="field:'projectNumber',width:80,align:'center'">项目编号</th>
                    <th data-options="field:'the_Department',width:80,align:'center'">所属部门</th>
                    <th data-options="field:'loan_Contacts',width:80,align:'center'">联系人</th>
                    <th data-options="field:'loan_ContactsTEL',width:150,align:'center'">联系电话</th>
                    <th data-options="field:'house_Located',width:80,align:'center'">房屋坐落</th>
                    <th data-options="field:'basic_CreateTime',width:150,align:'center'">登记日期</th>
                    <th data-options="field:'basic_State',width:80,align:'center'">项目状态</th>
                    <th data-options="field:'_operate',width:80,align:'center',formatter:formatOper">操作</th>
                </tr>
            </thead>
        </table>
    <!--区位状况勘察-->
    <div id="qu" class="easyui-window" title="区位状况" data-options="modal:true,closed:true,iconCls:'icon-save'" style="width:50%;height:90%;padding:10px;">
        <form id="ff" method="post">
            <table cellpadding="5">
                <tr hidden="hidden">
                    <td class="auto-style2" >项目编号</td>
                    <td class="auto-style1">
                        <input id="projectNumber" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">小区四至-东至:</td>
                    <td class="auto-style1">
                        <input id="location_East" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">小区四至-南至:</td>
                    <td class="auto-style1">
                        <input id="location_South" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">小区四至-西至:</td>
                    <td class="auto-style1">
                        <input id="location_West" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">区四至-北至:</td>
                    <td class="auto-style1">
                        <input id="location_North" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">位置环绕:</td>
                    <td class="auto-style1">
                        <select id="location_Position" class="easyui-combobox" name="dept" style="width:100%"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">交通情况:</td>
                    <td class="auto-style1">
                        <input id="location_Traffic" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">交通便捷度:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="location_Convenient"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">自然人文环境情况:</td>
                    <td class="auto-style1">
                        <input id="location_Humanity" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">自然人文环境质量:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="location_Quality"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">居住社区情况:</td>
                    <td class="auto-style1">
                        <input id="location_Community" class="easyui-textbox" type="text" name="email" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">居住社区成熟度:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="location_Mature"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">基础设施配套情况:</td>
                    <td class="auto-style1">
                        <input id="location_Facilities" class="easyui-textbox" type="text" name="subject" data-options="required:true">
                    </td>
                </tr>
                <tr>

                    <td class="auto-style2">基础设施配套度:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="ocation_Degree"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">配套设施:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="location_Supporting"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">有关说明:</td>
                    <td class="auto-style1">
                        <input id="location_Explain" class="easyui-textbox" name="message" data-options="multiline:true" style="height: 74px; width: 428px; margin-right: 0px;">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2"></td>
                    <td class="auto-style1">
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="addqu()" id="tian">保存</a>
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#qu').window('close')">取消</a>
                    </td>
                </tr>
            </table>
        </form>


    </div>
    <!--小区状况勘察-->
    <div id="xiao" class="easyui-window" title="小区状况" data-options="modal:true,closed:true,iconCls:'icon-save'" style="width:50%;height:90%;padding:10px;">
        <form id="ff" method="post">
            <table cellpadding="5">
                <tr>
                    <td class="auto-style2">项目案名:</td>
                    <td class="auto-style1">
                        <input id="village_CaseName" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">来源:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Cause"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">小区封闭性:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Close"></select>
                    </td>
                </tr>

                <tr>
                    <td class="auto-style2">居住小区楼宇结构:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Structure"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">交通组织方式:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Traffic"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">景观及绿化:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Green"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">容积率:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Volume"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">车位状况:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Parking"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">物业公司:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="village_Property"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">有关说明:</td>
                    <td class="auto-style1">
                        <input id="village_Explain" class="easyui-textbox" name="message" data-options="multiline:true" style="height: 74px; width: 428px; margin-right: 0px;">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2"></td>
                    <td class="auto-style1">
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="addxiao()">保存</a>
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#xiao').window('close')">取消</a>
                    </td>
                </tr>
            </table>
        </form>
    </div>
    <!--建筑公共部分状况勘察-->
    <div id="jian" class="easyui-window" title="建筑公共部分状况" data-options="modal:true,closed:true,iconCls:'icon-save'" style="width:50%;height:90%;padding:10px;">
        <table cellpadding="5">
            <tr>
                <td class="auto-style2">所在楼号:</td>
                <td class="auto-style1">
                    <input id="floor_Number" class="easyui-textbox" type="text" name="name" data-options="required:true">
                </td>
            </tr>
            <tr>
                <td class="auto-style2">地图:</td>
                <td class="auto-style1" style="width:60%;height:350px">
                    <div id="container" style="width:100%;height:100%"></div>

                </td>
            </tr>
            <tr>
                <td class="auto-style2">定位坐标:</td>
                <td class="auto-style1">
                    <input id="floor_Landmark" class="easyui-textbox" type="text" name="name1">
                </td>
            </tr>
            <tr>
                <td class="auto-style2">定位地址:</td>
                <td class="auto-style1">
                    <input id="floor_Address" class="easyui-textbox" type="text" name="name2">
                </td>
            </tr>

            <tr>
                <td class="auto-style2">房屋结构:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_HouseStructure"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">建筑类型:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_BuildType"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">外立面装饰:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_Facade"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">公共部位装饰:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_Public"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">电梯:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_Lift"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">电梯个数:</td>
                <td class="auto-style1">
                    <input id="floor_LiftNum" class="easyui-textbox" type="number" name="name" data-options="required:true">
                </td>
            </tr>
            <tr>
                <td class="auto-style2">供气:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_Gas"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">供水:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_Water"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">供暖:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_Warm"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">门禁系统:</td>
                <td class="auto-style1">
                    <select class="easyui-combobox" name="language" id="floor_Door"></select>
                </td>
            </tr>
            <tr>
                <td class="auto-style2">其他说明:</td>
                <td class="auto-style1">
                    <input id="floor_Explain" class="easyui-textbox" name="message" data-options="multiline:true" style="height: 74px; width: 428px; margin-right: 0px;">
                </td>
            </tr>
            <tr>
                <td class="auto-style2"></td>
                <td class="auto-style1">
                    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="addjian()">保存</a>
                    <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#jian').window('close')">取消</a>
                </td>
            </tr>
        </table>
    </div>
    <!--室内状况勘察-->
    <div id="shi" class="easyui-window" title="室内状况" data-options="modal:true,closed:true,iconCls:'icon-save'" style="width:50%;height:90%;padding:10px;">
        <form id="ff" method="post">
            <table cellpadding="5">
                <tr>
                    <td class="auto-style2">房屋实际用途:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="indoor_Purpose"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">总楼层:</td>
                    <td class="auto-style1">
                        <input id="indoor_LayerNum" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">所在楼层:</td>
                    <td class="auto-style1">
                        <input id="indoor_Layer" class="easyui-textbox" type="text" name="name" data-options="required:true">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">朝向:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="indoor_Orientation"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">住宅类型:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="indoor_Residence"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">户型:</td>
                    <td class="auto-style1">
                        <input id="indoor_Bedroom" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:10%">卧室
                        <input id="indoor_Hall" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:10%">客厅
                        <input id="indoor_Toilet" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:10%">卫生间
                        <input id="indoor_Kitchen" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:10%">厨房
                        <input id="indoor_Balcony" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:10%">阳台
                        <input id="indoor_Terrace" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:10%">露台
                        <input id="indoor_Yard" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:10%">小院
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">客厅装修程度:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" style="width:45%" id="s1"></select>
                        <select class="easyui-combobox" name="language" style="width:45%" id="indoor_HallDegree"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">客厅装修情况:</td>
                    <td class="auto-style1">
                        内墙：<input id="Checkbox1" type="checkbox" value="涂料" class="living_Wall" />涂料
                        <input id="Checkbox1" type="checkbox" value="壁纸" class="living_Wall" />壁纸
                        <input id="Checkbox1" type="checkbox" value="石材" class="living_Wall" />石材
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="living_Wall" />瓷砖&nbsp;&nbsp;
                        其他<input id="livingWall_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        顶棚：<input id="Checkbox1" type="checkbox" value="涂料" class="living_Ceiling" />涂料
                        <input id="Checkbox1" type="checkbox" value="吊顶" class="living_Ceiling" />吊顶&nbsp;&nbsp;
                        其他<input id="livingCeiling_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        地面：<input id="Checkbox1" type="checkbox" value="地砖" class="living_Ground" />地砖
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="living_Ground" />瓷砖
                        <input id="Checkbox1" type="checkbox" value="混凝土" class="living_Ground" />混凝土
                        <input id="Checkbox1" type="checkbox" value="木地板" class="living_Ground" />木地板
                        <input id="Checkbox1" type="checkbox" value="地板革" class="living_Ground" />地板革&nbsp;&nbsp;
                        其他<input id="livingGround_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">居室装修程度:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="indoor_RoomDegree"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">居室装修情况:</td>
                    <td class="auto-style1">
                        内墙：<input id="Checkbox1" type="checkbox" value="涂料" class="room_Wall" />涂料
                        <input id="Checkbox1" type="checkbox" value="壁纸" class="room_Wall" />壁纸
                        <input id="Checkbox1" type="checkbox" value="石材" class="room_Wall" />石材
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="room_Wall" />瓷砖&nbsp;&nbsp;
                        其他<input id="roomWall_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        顶棚：<input id="Checkbox1" type="checkbox" value="涂料" class="room_Ceiling" />涂料
                        <input id="Checkbox1" type="checkbox" value="吊顶" class="room_Ceiling" />吊顶&nbsp;&nbsp;
                        其他<input id="roomCeiling_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        地面：<input id="Checkbox1" type="checkbox" value="地砖" class="room_Ground" />地砖
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="room_Ground" />瓷砖
                        <input id="Checkbox1" type="checkbox" value="混凝土" class="room_Ground" />混凝土
                        <input id="Checkbox1" type="checkbox" value="木地板" class="room_Ground" />木地板
                        <input id="Checkbox1" type="checkbox" value="地板革" class="room_Ground" />地板革&nbsp;&nbsp;
                        其他<input id="roomGround_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">卫生间装修程度:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="indoor_ToiletDegree"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">卫生间装修情况:</td>
                    <td class="auto-style1">
                        内墙：<input id="Checkbox1" type="checkbox" value="涂料" class="toilet_Wall" />涂料
                        <input id="Checkbox1" type="checkbox" value="壁纸" class="toilet_Wall" />壁纸
                        <input id="Checkbox1" type="checkbox" value="石材" class="toilet_Wall" />石材
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="toilet_Wall" />瓷砖&nbsp;&nbsp;
                        其他<input id="toiletWall_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        顶棚：<input id="Checkbox1" type="checkbox" value="涂料" class="toilet_Ceiling" />涂料
                        <input id="Checkbox1" type="checkbox" value="吊顶" class="toilet_Ceiling" />吊顶&nbsp;&nbsp;
                        其他<input id="toiletCeiling_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        地面：<input id="Checkbox1" type="checkbox" value="地砖" class="toilet_Ground" />地砖
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="toilet_Ground" />瓷砖
                        <input id="Checkbox1" type="checkbox" value="混凝土" class="toilet_Ground" />混凝土
                        <input id="Checkbox1" type="checkbox" value="木地板" class="toilet_Ground" />木地板
                        <input id="Checkbox1" type="checkbox" value="地板革" class="toilet_Ground" />地板革&nbsp;&nbsp;
                        其他<input id="toiletGround_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        洁具情况：<input id="Checkbox1" type="checkbox" value="洁具齐全" class="toilet_Sanitary" />洁具齐全
                        <input id="Checkbox1" type="checkbox" value="浴霸" class="toilet_Sanitary" />浴霸&nbsp;&nbsp;
                        其他<input id="toiletSanitary_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">厨房装修程度:</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="indoor_KitchenDegree"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">厨房装修情况:</td>
                    <td class="auto-style1">
                        内墙：<input id="Checkbox1" type="checkbox" value="涂料" class="kitchen_Wall" />涂料
                        <input id="Checkbox1" type="checkbox" value="壁纸" class="kitchen_Wall" />壁纸
                        <input id="Checkbox1" type="checkbox" value="石材" class="kitchen_Wall" />石材
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="kitchen_Wall" />瓷砖&nbsp;&nbsp;
                        其他<input id="kitchenWall_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        顶棚：<input id="Checkbox1" type="checkbox" value="涂料" class="kitchen_Ceiling" />涂料
                        <input id="Checkbox1" type="checkbox" value="吊顶" class="kitchen_Ceiling" />吊顶&nbsp;&nbsp;
                        其他<input id="kitchenCeiling_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        地面：<input id="Checkbox1" type="checkbox" value="地砖" class="kitchen_Ground" />地砖
                        <input id="Checkbox1" type="checkbox" value="瓷砖" class="kitchen_Ground" />瓷砖
                        <input id="Checkbox1" type="checkbox" value="混凝土" class="kitchen_Ground" />混凝土
                        <input id="Checkbox1" type="checkbox" value="木地板" class="kitchen_Ground" />木地板
                        <input id="Checkbox1" type="checkbox" value="地板革" class="kitchen_Ground" />地板革&nbsp;&nbsp;
                        其他<input id="kitchenGround_Other" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                        灶台情况：<input id="Checkbox1" type="checkbox" value="成套橱柜" class="kitchen_Cooking" />成套橱柜
                        <input id="Checkbox1" type="checkbox" value="灶台" class="kitchen_Cooking" />灶台
                        <input id="Checkbox1" type="checkbox" value="瓷盆" class="kitchen_Cooking" />瓷盆
                        其他<input id="kitchenCookingO_ther" class="easyui-textbox" type="text" name="name" data-options="required:true" style="width:20%"><br />
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2">有关说明:</td>
                    <td class="auto-style1">
                        <input id="indoor_Explain" class="easyui-textbox" name="message" data-options="multiline:true" style="height: 74px; width: 428px; margin-right: 0px;">
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2"></td>
                    <td class="auto-style1">
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="addshi()">保存</a>
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#shi').window('close')">取消</a>
                    </td>
                </tr>
            </table>
        </form>
    </div>
    <!--现场照片提供-->
    <div id="xian" class="easyui-window" title="现场照片提供" data-options="modal:true,closed:true,iconCls:'icon-save'" style="width:70%;height:90%;padding:10px;">
        <form id="ff" method="post">
            <table cellpadding="5">
                <tr>
                    <td class="auto-style2">照片</td>
                    <td class="auto-style1">
                        <select class="easyui-combobox" name="language" id="location_Mature"></select>
                    </td>
                </tr>
                <tr>
                    <td class="auto-style2"></td>
                    <td class="auto-style1">
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="addxian()" id="tian">保存</a>
                        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#xian').window('close')">取消</a>
                    </td>
                </tr>
            </table>
        </form>
    </div>
    <!--询价记录-->
    <div id="xun" class="easyui-window" title="询价记录" data-options="modal:true,closed:true,iconCls:'icon-save'" style="width:50%;height:90%;padding:10px;">
        <a href="javascript:void(0)" class="easyui-linkbutton" onclick="tianaxun()">新增询价</a>
        <table class="easyui-datagrid" title="询价记录" style="width:700px;height:250px"
               data-options="singleSelect:true,collapsible:true" id="xunjia">
            <thead>
                <tr>
                    <th data-options="field:'inquiry_Id',width:80,align:'center'">编号</th>
                    <th data-options="field:'projectNumber',width:80,align:'center'">项目编号</th>
                    <th data-options="field:'inquiry_UnitPrice',width:100,align:'center'">建议评估单价</th>
                    <th data-options="field:'inquiry_Content',width:150,align:'center'">询价内容及其他</th>
                    <th data-options="field:'inquiry_Time',width:150,align:'center'">询价日期</th>
                </tr>
            </thead>
        </table>
        <!--添加询价记录-->
        <div id="axun" class="easyui-window" title="添加询价" data-options="modal:true,closed:true,iconCls:'icon-save'" style="width:50%;height:50%;padding:10px;">
            <form id="ff" method="post">
                <table cellpadding="5">
                    <tr>
                        <td class="auto-style2" style="text-align:right">建议评估单价</td>
                        <td class="auto-style1">
                            <input id="inquiry_UnitPrice" class="easyui-textbox" type="text" name="name" data-options="required:true">
                        </td>
                    </tr>
                    <tr>
                        <td class="auto-style2" style="text-align:right">询价内容及其他</td>
                        <td class="auto-style1">
                            <input id="inquiry_Content" class="easyui-textbox" type="text" name="name" data-options="required:true">
                        </td>
                    </tr>
                    <tr>
                        <td class="auto-style2" style="text-align:right">询价日期</td>
                        <td class="auto-style1">
                            <input id="inquiry_Time" class="easyui-textbox" type="text" name="name" data-options="required:true">
                        </td>
                    </tr>
                    <tr>
                        <td class="auto-style2"></td>
                        <td class="auto-style1">
                            <a href="javascript:void(0)" class="easyui-linkbutton" onclick="addxun()">保存</a>
                            <a href="javascript:void(0)" class="easyui-linkbutton" onclick="$('#axun').window('close')">取消</a>
                        </td>
                    </tr>
                </table>
            </form>
        </div>
    </div>

    <!--加载地图-->
    <script>
        var map = new BMap.Map("container");          // 创建地图实例
        var point = new BMap.Point(116.404, 39.915);  // 创建点坐标
        map.centerAndZoom(point, 15);                 // 初始化地图，设置中心点坐标和地图级别
        map.centerAndZoom(new BMap.Point(116.404, 39.915), 11);
        map.addControl(new BMap.NavigationControl());
        map.addControl(new BMap.ScaleControl());
        map.addControl(new BMap.OverviewMapControl());
        map.addControl(new BMap.MapTypeControl());
        map.enableScrollWheelZoom(true);
        map.setCurrentCity("北京"); // 仅当设置城市信息时，MapTypeControl的切换功能才能可用
        var marker = new BMap.Marker(point);        // 创建标注
        map.addOverlay(marker);
        marker.enableDragging();
        map.addEventListener("click", function (e) {
            map.removeOverlay(marker);
            point = new BMap.Point(e.point.lng, e.point.lat);
            marker = new BMap.Marker(point);
            map.addOverlay(marker);
            map.centerAndZoom(point, 15);
            var geoc = new BMap.Geocoder();
            var pt = e.point;
            geoc.getLocation(pt, function (rs) {
                var addComp = rs.addressComponents;
                var t1 = addComp.province + addComp.city + addComp.district + addComp.street + addComp.streetNumber;
                var t2 = e.point.lng + ',' + e.point.lat;
                $('#floor_Landmark').textbox('setValue', t2);
                $('#floor_Address').textbox('setValue', t1);
            });
        });
        map.addEventListener("click", function (e) {
        });
    </script>

</body>
</html>

